package org.example.controller;


import org.example.entity.LoginDTO;
import org.example.entity.ResponseModel;
import org.example.service.LoginService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RestController;

@RestController
public class LoginController {


    @Autowired
    private LoginService loginService;

    @PostMapping("/login")
    public ResponseModel<String> login(@RequestBody LoginDTO dto)
    {
        return loginService.checkLogin(dto);
    }



}
